package com.example.demo.dao;

import com.example.demo.pojo.OrderForm;
import com.example.demo.util.GetOrderSelId;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface OrderFormDao {
    List<GetOrderSelId> getOrderFormAll();
    int deleteByPrimaryKey(Integer orderid);

    int insert(OrderForm record);

    int insertSelective(OrderForm record);

    OrderForm selectByPrimaryKey(Integer orderid);

    int updateByPrimaryKeySelective(OrderForm record);

    int updateByPrimaryKey(OrderForm record);
    int updateOrderStatuId(@Param("id") int id);
    int updateCancelled(@Param("id") int id);
    int updateOrderStatuDeliverGoods(@Param("id") int id);
    int updateOrderStatuAfterSale(int id);
    List<GetOrderSelId> getOrderUserId(@Param("userId") Integer userId);
    List<GetOrderSelId> getOrderWareId(@Param("wareId") Integer wareId);
    GetOrderSelId getOrder(@Param("order") String order);
    OrderForm getOrderNumber(@Param("orderNumber") String  orderNumber);

    int updateOrderStatus(@Param("orderStatusId") int orderStatusId,@Param("orderNumber") String ordernumber);

    OrderForm getOne(String ordernumber);
}